import rexi_fun
day=rexi_fun.day()
print(day)
rexi_fun.cmd("touch "+day+" && open "+day+" &")
import time
time.sleep(1)
with open(day) as file_object:
    txt = file_object.read()
while True:
    time.sleep(1)
    #print(rexi_fun.cmd("ls -l "+day))
    with open(day) as file_object:
        new = file_object.read()
        if txt!=new:
            print("已修改")
            break
rexi_fun.cmd("git add *")
#rexi_fun.cmd("cp readme.txt README.md")#这句有bug，已修复改到调用这个python脚本的shell脚本，gitee不会像github一样把命令行兼容性易用性更高的readme.txt自动识别为readme，建议在readme.txt里写readme，日循环脚本会自动把readme.txt拷贝到README.md兼容gitee的显示
rexi_fun.cmd("python auto_git_commit.py")
rexi_fun.cmd("git push")
